<template>
<div id="detail">
  <navigation></navigation>
  <div v-if="data" class="content" v-html="data.article.content"></div>
  <pageFooter></pageFooter>
</div>
</template>
<script>
import navigation from "@/components/navigation/index";
import pageFooter from "@/components/footer/index";

import {
  NetworkUtil
} from "@/lib/util"

export default {
  components: {
    navigation,
    pageFooter
  },
  data() {
    return {
      data: {
        data: ''
      }
    }
  },
  created() {
    NetworkUtil.request({
      url: '/api/news/detail/' + this.$route.params.id,
      method: 'get'
    }, info => {
      this.data = info
    }, err => {
      console.log(err)
    })
  },
  methods: {

  }
}
</script>
<style lang="less" rel="stylesheet/less">
@import "index.less";
</style>
